package com.vogue.supplymall.shop.domain.service.impl;

import com.vogue.ssm.database.dao.BaseDao;
import com.vogue.supplymall.shop.domain.dao.AdministrativeareaDao;
import com.vogue.supplymall.shop.domain.model.Administrativearea;
import com.vogue.supplymall.shop.domain.service.AdministrativeareaService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * The type Administrativearea service.
 *
 * @aouthor: zhangliang
 * @date: Create in 2017-12-25
 */
@Service("administrativeareaService")
public class AdministrativeareaServiceImpl extends BaseServiceImpl<Administrativearea, Long> implements AdministrativeareaService {
    @Resource
    private AdministrativeareaDao administrativeareaDao;

    /**
     * Instantiates a new Administrativearea service.
     *
     * @param baseDao the base dao
     */
    public AdministrativeareaServiceImpl(BaseDao<Administrativearea, Long> baseDao) {
        super(baseDao);
    }

    @Override
    public List<Administrativearea> findAreaByLevel(Integer level) {
        return administrativeareaDao.findArea(level);
    }

	@Override
	public List<Administrativearea> findAllAreaOfMinLevel(Integer level) {
		
		return administrativeareaDao.findAllAreaOfMinLevel(level);
	}
    
}
